﻿<?xml version="1.0" encoding="utf-8" ?>
<objects xmlns="http://www.springframework.net">
  
    <!--Define my main object.-->
    <object id="MainWindowViewModel" type="Eirene.WPF.ViewModel.MainWindowViewModel">

        <!--And set its welcome message property.-->
        <property name="Welcome" value="List of hats for sale:" />

        <!--Set items to an item container, and add items. -->
        <!--See http://www.springframework.net/docs/1.3.0/reference/html/objects.html#objects-collections-values -->
        <property name="Hats">
            <object type="ItemContainer">
                <constructor-arg>
                    <list element-type="Item">
                        <object id="item1" type="Item" singleton="false">
                            <property name="ItemName" value="Witches Hat" />
                            <property name="Colour" value="Black" />
                            <property name="Price" value="10" />
                            <property name="Owners">
                                <list element-type="Owner">
                                    <object id="owner1" type="Owner" singleton="false">
                                        <property name="FirstName" value="Evil" />
                                        <property name="LastName" value="Witch" />
                                        <property name="IsDefault" value="true" />
                                    </object>
                                    <object id="owner2" type="Owner" singleton="false">
                                        <property name="FirstName" value="Spooky" />
                                        <property name="LastName" value="Ghost" />
                                    </object>
                                </list>
                            </property>
                            <property name="Status" expression="@(Status)[1]" />
                        </object>
                        <object id="item2" type="Item" singleton="false">
                            <property name="ItemName" value="Beanie" />
                            <property name="Colour" value="Blue and yellow stripes" />
                            <property name="Price" value="5.55" />
                            <property name="Owners">
                                <list element-type="Owner">
                                    <object id="owner3" type="Owner" singleton="false">
                                        <property name="FirstName" value="Big" />
                                        <property name="LastName" value="Star" />
                                        <property name="IsDefault" value="true" />
                                    </object>
                                </list>
                            </property>
                            <property name="Status" expression="@(Status)[2]" />
                        </object>
                        <object id="item3" type="Item" singleton="false">
                            <property name="ItemName" value="Fez" />
                            <property name="Colour" value="Maroon with Black Tassel" />
                            <property name="Price" value="59.99" />
                            <property name="Owners">
                                <list element-type="Owner">
                                    <object id="owner4" type="Owner" singleton="false">
                                        <property name="FirstName" value="Ali" />
                                        <property name="LastName" value="Baba" />
                                        <property name="IsDefault" value="true" />
                                    </object>
                                </list>
                            </property>
                            <property name="Status" expression="@(Status)[0]" />
                        </object>
                    </list>
                </constructor-arg>
                <property name="BaseDefaultOwner">
                    <object id="owner" type="Owner" singleton="false">
                        <property name="FirstName" value="Mad" />
                        <property name="LastName" value="Hatter" />
                        <property name="IsDefault" value="true" />
                    </object>
                </property>
            </object>
        </property>
      
    </object>

    <!--Define status types-->
    <object id="Status" type="System.Collections.Generic.List&lt;Status&gt;">
        <constructor-arg>
            <list element-type="Status">
                <object type="Status">
                    <constructor-arg value="New" />
                </object>
                <object type="Status">
                    <constructor-arg value="Rental" />
                </object>
                <object type="Status">
                    <constructor-arg value="Used" />
                </object>
            </list>
        </constructor-arg>
    </object>
  
</objects>
